﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MyVoteMVC.Data;
using MyVoteMVC.Domain;
using MyVoteMVC.Common;
using MyVoteMVC.Common.Objects;
using MyVoteMVC.Data.Repositories;

namespace MyVoteMVC.Service
{
    public interface IProjectService : IDisposable
    {
        List<VT_Projects> FindAllProject(string strYear, string strType, string key);
        //增加
        bool AddProjectImage(string projectID, byte[] projectImage, byte[] ThumbnailImage);
        //删除
        bool DeleteProjectImage(string projectID);
        //修改
        bool ModifyProjectImage(string projectID, byte[] projectImage, byte[]  ThumbnailImage);

        //增加
        string CreateProjects(string projectYear, string projectAddress, string projectName, string projectType, string projectAwards, string projectDescription, byte[] projectImage, byte[] ThumbnailImage);

        //编辑
        bool EditProjects(string projectID, string projectYear, string projectAddress, string projectName, string projectType, string projectAwards, string projectDescription);

        //删除
        bool DeleteProjects(string projectID);

        //获取
        IList<VT_Projects> GetAllProjects();

        //通过年份获取
        IList<VT_Projects> GetProjectsByYear(string strYear);

        //通过类型获取
        IList<VT_Projects> GetProjectsByType(string strType);

        VT_Projects GetProjectById(string projectId);
         //获取 所有出现的年份
        List<string> GetALLYear();
        //获取所有出现的类型
        IList<string> GetALLType();

        bool DeleteProjects(List<VT_Projects> v_Projects);

        IList<VT_Projects> FuzzySearch(string strFindContent);

        //获取该活动的问题相关的选项的project
        List<VT_Projects> GetALLProjectsByActivity(string activityID);
        List<string> GetProjectsTypeByActivity(string activityID);
        List<string> GetProjectsYearByActivity(string activityID);
        List<string> GetProjectsYearGroupByActivity(string activityID);
    }
}
